<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>更换头像</title>
    <link rel="stylesheet" href="../assets/lib/layui/css/layui.css">
    <link rel="stylesheet" href="../assets/lib/cropper/cropper.css">
    <link rel="stylesheet" href="../assets/css/user/user_avatar.css">
    <script src="../assets/lib/layui/layui.js"></script>
    <script src="../assets/lib/jquery.js"></script>
    <script src="../assets/lib/cropper/Cropper.js"></script>
    <script src="../assets/lib/cropper/jquery-cropper.js"></script>
    <script src="../assets/js/baseAPI.js"></script>
    <script src="../assets/js/user/user_avatar.js"></script>
</head>
<body>
    <div class="layui-card">
        <div class="layui-card-header">更换头像</div>
        <div class="layui-card-body">
            <div class="row1">
                <div class="cropper-box">
                    <img src="../assets/images/sample.jpg" id="img" alt="">
                </div>
                <div class="preview-box">
                    <div>       <!-- 指定预览区 -->
                        <div class="img-preview w100"></div>
                        <p class="size">100 x 100</p>
                    </div>
                    <div>       <!-- 指定预览区 -->
                        <div class="img-preview w50"></div>
                        <p class="size">50 x 50</p>
                    </div>
                </div>
            </div>

            <div class="row2">
                <input type="file" id="file" accept="image/png,image/jpeg">
                <button type="button" class="layui-btn" id="btnChooseImg">上传</button>
                <button type="button" class="layui-btn layui-btn-normal" id="btnUpload">确定</button>
            </div>
        </div>
    </div>
</body>
</html>